package com.algebra.activiti.util.common;


import com.algebra.activiti.domain.ActivitiVariable;
import com.algebra.activiti.service.ActivitiVariableService;

public class BusinessTaskUtil {


    public void actBusinessApplyForm(String userId, String businessId, String result){
        ActivitiVariable activitiVariable = new ActivitiVariable();
        activitiVariable.setId(Integer.parseInt(businessId));
        activitiVariable.setApplyStr(result);
        ActivitiVariableService activitiVariableService =
                (ActivitiVariableService)ApplicationContextUtil.getBeanById("activitiVariableServiceImpl");
        activitiVariableService.updateById(activitiVariable);
    }

    public void actBusinessApproveForm(String userId, String businessId, String result){
        ActivitiVariable activitiVariable = new ActivitiVariable();
        activitiVariable.setId(Integer.parseInt(businessId));
        activitiVariable.setApproveStr(result);
        ActivitiVariableService activitiVariableService =
                (ActivitiVariableService)ApplicationContextUtil.getBeanById("ActivitiVariableServiceImpl");
        activitiVariableService.updateById(activitiVariable);
    }

}
